<!DOCTYPE html>
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">

    <!--引用百度地图API-->
    <style type="text/css">
        html, body {
            margin: 0;
            padding: 0;
        }

        #setZ-index {
            z-index: 0;
        }

        .iw_poi_title {
            color: #CC5522;
            font-size: 14px;
            font-weight: bold;
            overflow: hidden;
            padding-right: 13px;
            white-space: nowrap
        }

        .iw_poi_content {
            font: 12px arial, sans-serif;
            overflow: visible;
            padding-top: 4px;
            white-space: -moz-pre-wrap;
            word-wrap: break-word
        }

        .searchbox-content {
            width: 368px;
            border-radius: 2px 0 0 2px;
            background: #fff;
        }

        #searchbox #searchbox-container {
            position: relative;
            z-index: 2;
            pointer-events: auto;
            width: 216px;
            float: left;
            box-sizing: border-box;
            box-shadow: 1px 2px 1px rgba(0, 0, 0, .15);
        }

        #sole-searchbox-content #suggestId {
            box-sizing: border-box;
            border: 0;
            padding: 9px 0;
            border-left: 10px solid transparent;
            border-right: 10px solid transparent;
            line-height: 20px;
            font-size: 16px;
            height: 38px;
            color: #333;
            position: relative;
            border-radius: 2px 0 0 2px;
        }

        .searchbox-content .searchbox-content-common {
            box-sizing: border-box;
            float: left;
            width: 217px;
            height: 38px;
        }

        #searchbox #search-button {
            pointer-events: auto;
            background: url(http://webmap0.map.bdstatic.com/wolfman/static/common/images/new/searchbox_f175577.png) no-repeat 0 -76px #3385ff;
            width: 57px;
            height: 38px;
            float: left;
            border: 0;
            padding: 0;
            cursor: pointer;
            border-radius: 0 2px 2px 0;
            box-shadow: 1px 2px 1px rgba(0, 0, 0, .15);
        }

        .clearfix {
            position: absolute;
            top: 16px;
            right: 14px;
        }
    </style>

    <title>限高杆故障申报</title>
</head>
<body>
<div class="box">
    <div class="box-body">
        <table id="mainDataTables" class="table table-bordered table-striped" cellspacing="0" width="100%">
            <thead>
            <tr>
                <th><input onchange="$.checkChange()" type="checkbox" id="batch_check"></th>
                <th>序号</th>
                <th>限高杆图片</th>
                <th>报告人</th>
                <th>报告时间</th>
                <th>维护单位</th>
                <th>企业审核人</th>
                <th>限高杆详情</th>
                <th>限高杆故障详情</th>
                <th>操作</th>
            </tr>
            </thead>
        </table>
    </div>
</div>


<!--故障上报/详情modal-->
<div class="modal fade bs-example-modal-sm" id="addFaultModal" tabindex="-1" role="dialog"
     aria-labelledby="addFaultModalLabel"
     aria-hidden="true">
    <div class="modal-dialog" style="width: 800px;">
        <div class="modal-content">
            <div class="modal-header">
                <label class="modal-title" id="addFaultModalLabel"></label>
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"
                        onclick="$.closeAddFaultModal()">
                    <span aria-hidden="true">&times;</span></button>
                </button>
            </div>
            <div class="modal-body" id="add-body" style="overflow: auto">
                <table class="table table-bordered table-striped">
                    <tr>
                        <td class="col-sm-3">上报人员</td>
                        <td class="col-sm-3"><span id="addFault_creatorName"></span></td>
                        <td class="col-sm-3">上报人员电话</td>
                        <td class="col-sm-3"><span id="addFault_creatorPhone"></span></td>
                    </tr>
                    <tr>
                        <td class="col-sm-3">设施位置名称</td>
                        <td class="col-sm-3"><span id="addFault_roadName"></span>
                            <button style="float: right;" id="addFault_DTBtn" onclick="$.highLeverDTModal()"><i
                                    class="fa fa-align-justify">
                            </i></button>
                            <button style="float: right;" id="addFault_signMapBtn" onclick="$.selectMap()"><i
                                    class="fa fa-map-marker">
                            </i></button>
                        </td>
                        <td class="col-sm-3">预计维修金额(元)</td>
                        <td class="col-sm-3"><input type="text" id="addFault_money"
                                                    onkeyup="onlyNumber(this)" placeholder="0.00"/></td>
                    </tr>
                    <tr>
                        <td class="col-sm-3">所属路口路段</td>
                        <td colspan="3"><span id="addFault_address"></span></td>
                    </tr>
                    <tr>
                        <td class="col-sm-3">故障类型</td>
                        <td class="col-sm-3"><select class="form-control" id="addFault_faultType"></select></td>
                        <td class="col-sm-3">故障等级</td>
                        <td class="col-sm-3">
                            <select class="form-control" id="addFault_faultLevel">
                                <option value="1">一级</option>
                                <option value="2">二级</option>
                                <option value="3">三级</option>
                                <option value="4">四级</option>
                                <option value="5">五级</option>
                            </select></td>
                    </tr>
                    <tr>
                        <td>故障原因</td>
                        <td colspan="3">
                            <textarea class="form-control" id="addFault_faultReason"
                                      style="height: 80px"></textarea>
                        </td>
                    </tr>
                    <tr>
                        <td>故障图片</td>
                        <td colspan="3" rowspan="2">
                            <img id="addFault_faultPhoto" src="../images/default_photo.png"
                                 onclick="$.openUpPic()"
                                 style="width:83%;height: 300px;cursor: pointer"/>
                        </td>
                    </tr>
                </table>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-warning" data-dismiss="modal"
                        onclick="$.closeAddFaultModal()"><i class="fa fa-trash-o"></i> 取消
                </button>
                <button type="button" id="reportBtn" onclick="$.reportHighLeverFault()" class="btn btn-primary"><i
                        class="glyphicon glyphicon-upload"></i> 上报
                </button>
                <button type="button" style="display: none" id="updateBtn" onclick="$.updateFault()"
                        class="btn btn-primary"><i class="glyphicon glyphicon-upload"></i> 保存
                </button>
            </div>
            <input type="hidden" id="addFault_highLeverFaultId">
            <input type="hidden" id="addFault_highLeverId">
            <input type="hidden" id="addFault_highLeverOrgId">
            <input type="hidden" id="addFault_highLeverMainOrgId">
        </div>
    </div>
</div>

<!--限高杆datatable——>modal-->
<div id="highLeverDTModal" class="modal fade" tabindex="-1" role="dialog"
     aria-labelledby="highLeverDTModalLabel" aria-hidden="true">
    <div class="modal-dialog" style="width: 1100px;">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"
                        onclick="$.closeHighLeverDTModal()">
                    <span aria-hidden="true">&times;</span></button>
                <b class="modal-title" id="highLeverDTModalLabel"></b>
            </div>
            <div class="modal-body">
                <table id="highLeverDTDataTables" class="table table-bordered table-striped"
                       cellspacing="0" width="100%">
                    <thead>
                    <tr>
                        <th>序号</th>
                        <th>限高杆图片</th>
                        <th>地址</th>
                        <th>行政区号</th>
                        <th>养护公司</th>
                        <th>采集人</th>
                        <th>创建时间</th>
                        <th>限高杆详情</th>
                        <th>上报</th>
                    </tr>
                    </thead>
                </table>
            </div>
        </div>
    </div>
</div>

<!-- 限高杆详情 modal-->
<div id="detailInfoModal" class="modal fade" tabindex="-1" role="dialog"
     aria-labelledby="detailInfoModalLabel" aria-hidden="true">
    <div class="modal-dialog" style="width: 800px;">
        <div class="modal-content">
            <form id="detailInfoModalForm"
                  class="form-horizontal" role="form" method="post">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close"
                            onclick="$.closeDetailInfoModal()">
                        <span aria-hidden="true">&times;</span></button>
                    <b class="modal-title" id="detailInfoModalLabel"></b>
                </div>
                <div class="modal-body">
                    <div class="row">
                        <div class="col-sm-6">
                            <div class="form-group">
                                <label class="col-sm-3 control-label">地址</label>
                                <div class="col-sm-3" style="padding-right: 0">
                                    <input type="text" class="form-control" id="detail_province"
                                           placeholder="省" style="padding-right: 10px" readonly>
                                </div>
                                <div class="col-sm-3" style="padding-left: 7px; padding-right: 7px">
                                    <input type="text" class="form-control" id="detail_city"
                                           placeholder="市" style="padding-right: 10px" readonly>
                                </div>
                                <div class="col-sm-3" style="padding-left: 0">
                                    <input type="text" class="form-control" id="detail_area"
                                           placeholder="区/县" style="padding-right: 10px" readonly>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">坐标</label>
                                <div class="col-sm-8" style="padding-right: 0">
                                    <input type="text" class="form-control" id="detail_coordinate"
                                           placeholder="坐标" style="padding-right: 10px" readonly>
                                </div>
                                <div class="col-sm-1">
                                    <button type="button" style="height: 34px;float: right;" class="myBtnUpdate"><i
                                            class="fa fa-map-marker"></i></button>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">监管单位</label>
                                <div class="col-sm-9">
                                    <input type="text" class="form-control" id="detail_mainOrgName"
                                           placeholder="监管单位" readonly>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">养护公司</label>
                                <div class="col-sm-9">
                                    <input type="text" class="form-control" id="detail_orgName"
                                           placeholder="养护公司" readonly>
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-sm-3 control-label">路名</label>
                                <div class="col-sm-9">
                                    <input type="text" class="form-control" id="detail_roadName"
                                           placeholder="起始路口" readonly>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">起始路口</label>
                                <div class="col-sm-9">
                                    <input type="text" class="form-control" id="detail_startRoad"
                                           placeholder="起始路口" readonly>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">结束路口</label>
                                <div class="col-sm-9">
                                    <input type="text" class="form-control" id="detail_endRoad"
                                           placeholder="结束路口" readonly>
                                </div>
                            </div>
                        </div>
                        <div class="col-sm-6">
                            <div class="form-group">
                                <label class="col-sm-3 control-label">限高杆照片</label>
                                <div class="col-sm-9">
                                    <img id="detail_photo" src="" onclick="$.showPicModal(src)"
                                         style="cursor: pointer;height: 185px; width: 260px">
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">安装企业</label>
                                <div class="col-sm-9">
                                    <input type="text" class="form-control" id="detail_installOrg"
                                           placeholder="安装企业" readonly>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">使用年限</label>
                                <div class="col-sm-9">
                                    <input type="text" class="form-control" id="detail_serviceLife"
                                           placeholder="安装企业" readonly>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">采集人</label>
                                <div class="col-sm-9">
                                    <input type="text" class="form-control" id="detail_creatorName"
                                           placeholder="采集人" readonly>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-primary pull-right btn-flat" data-dismiss="modal"
                            onclick="$.closeDetailInfoModal()" id="detail_okbtn">
                        <i class="glyphicon glyphicon-ok"></i> 完成
                    </button>
                    <button type="button" class="btn btn-primary pull-right btn-flat" data-dismiss="modal"
                            onclick="$.sureHighLever(0)" style="display: none;margin-right: 5px"
                            id="detail_reportbtn">
                        <i class="glyphicon glyphicon-eye-open"></i> 上报
                    </button>
                </div>
            </form>
        </div>
    </div>
</div>


<!--审核页面modal-->
<div class="modal fade bs-example-modal-sm" id="auditModal" tabindex="-1" role="dialog"
     aria-labelledby="auditModalLabel"
     aria-hidden="true">
    <div class="modal-dialog" style="width: 700px;">
        <div class="modal-content">
            <div class="modal-header">
                <label class="modal-title" id="auditModalLabel"></label>
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"
                        onclick="$.closeAuditModal()">
                    <span aria-hidden="true">&times;</span></button>
                </button>
            </div>
            <div class="modal-body" id="md-body" style="overflow: auto">
                <table class="table table-bordered table-striped">
                    <tr>
                        <td class="col-sm-3">故障编号</td>
                        <td class="col-sm-3"><span id="audit_faultId"></span></td>
                        <td class="col-sm-3">故障等级</td>
                        <td class="col-sm-3"><span id="audit_faultLevel"></span></td>
                    </tr>
                    <tr>
                        <td class="col-sm-3">故障类型</td>
                        <td class="col-sm-3"><span id="audit_faultType"></span></td>
                        <td class="col-sm-3">报告人</td>
                        <td class="col-sm-3"><span id="audit_faultCreatorName"></span></td>
                    </tr>
                    <tr>
                        <td class="col-sm-3">报告时间</td>
                        <td><span id="audit_faultTime"></span></td>
                        <td class="col-sm-3">预计维修金额(元)</td>
                        <td><span id="audit_faultMoney"></span></td>
                    </tr>
                    <tr>
                        <td colspan="1">审核反馈</td>
                        <td colspan="3">
                            <input type="text" class="form-control" id="audit_faultFeedback">
                        </td>
                    </tr>
                    <tr>
                        <td colspan="2">故障原因</td>
                        <td colspan="2">故障图片</td>
                    </tr>
                    <tr>
                        <td colspan="2">
                            <div style="height:130px;" id="audit_faultReason"></div>
                        </td>
                        <td colspan="2" rowspan="2">
                            <img id="audit_faultPhoto" src="" style="width:83%;cursor: pointer"
                                 onclick="$.showPicModal(src)">
                            <br/>
                            <span style="font-size: 5px;color: gray;">点击图片放大</span>
                        </td>
                    </tr>
                    <tr>
                        <td colspan="4">限高杆位置</td>
                    </tr>
                    <tr>
                        <td colspan="4" rowspan="3">
                            <iframe src="fault/map.html" id="audit_faultMap"
                                    style="width: 100%;height: 279px;"
                                    frameBorder=0
                                    scrolling=no></iframe>
                        </td>
                    </tr>
                </table>
                <input type="hidden" id="audit_signalMachineId">
            </div>
            <div class="modal-footer">
                <button type="submit" id="straight-button" class="btn btn-warning">
                    <span class="glyphicon glyphicon-ok-circle" aria-hidden="true"></span> 内部通过
                </button>
                <button type="submit" id="ac-button" class="btn btn-success">
                    <span class="glyphicon glyphicon-ok" aria-hidden="true"></span> 通过
                </button>
                <button id="notac-button" class="btn btn-danger">
                    <span class="glyphicon glyphicon-remove" aria-hidden="true"></span> 不通过
                </button>
                <button type="button" class="btn btn-primary" data-dismiss="modal"
                        onclick="$.closeAuditModal()"><i
                        class="fa fa-trash-o"></i> 取消
                </button>
            </div>
        </div>
    </div>
</div>
<!--图片上传-->
<div class="modal fade" id="upPictureModal" tabindex="-1" role="dialog"
     aria-labelledby="upPictureModalLabel" aria-hidden="true">
    <div class="modal-dialog modal-sm">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"
                        onclick="$.closeUpPhModal()">
                    <span aria-hidden="true">&times;</span>
                </button>
                <b class="modal-title" id="upPictureModalLabel"></b>
            </div>
            <div class="modal-body row">
                <div id="container" class="col-sm-12">
                    <a id="selectfiles" href="javascript:void(0);" class='btn btn-primary'>
                        <span class='glyphicon glyphicon-picture'></span> 选择图片</a>
                    <a id="postfiles" href="javascript:void(0);" class='btn btn-success'>
                        <span class='glyphicon glyphicon-send'></span> 开始上传</a>
                </div>
                <div id="ossfile" class="col-sm-12" style="margin-top: 20px;"></div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-primary" onclick="$.closeUpPhModal()">
                    <span class="glyphicon glyphicon-remove" aria-hidden="true"></span> 取消
                </button>
                <button type="button" class="btn btn-success" onclick="$.doneUpPhoto()">
                    <span class="glyphicon glyphicon-ok" aria-hidden="true"></span> 完成
                </button>
            </div>
        </div>
    </div>
</div>
<!--地图选择-->
<div id="selectMap" style="z-index: 0;margin-top: 22px" class="modal fade" tabindex="-1" role="dialog"
     aria-labelledby="label-map"
     aria-hidden="true">
    <div class="modal-dialog" style="width: 1200px;">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"
                        onclick="$.closeSelectMap()">
                    <span aria-hidden="true">&times;</span></button>
                <b class="modal-title" id="selectMaplabel">选择信号机</b>
            </div>
            <div class="modal-body" style="max-height:550px">
                <!--百度地图容器-->
                <div style="width:100%;height:500px;border:#ccc solid 1px;" id="dituContent"></div>
                <div id="searchbox" class="clearfix">
                    <div id="searchbox-container">
                        <div id="sole-searchbox-content" class="searchbox-content">
                            <div id="searchResultPanel"
                                 style="border:1px solid #C0C0C0;width:215px;height:auto; display:none;"></div>
                            <input id="suggestId" class="searchbox-content-common" type="text" name="word"
                                   autocomplete="off"
                                   maxlength="256" placeholder="搜地点" value="">
                        </div>
                    </div>
                    <button id="search-button" data-title="搜索" data-tooltip="1"></button>
                </div>
            </div>
        </div>
    </div>
</div>

<!--//地图-->
<div id="modal-map" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="label-map"
     aria-hidden="true">
    <div class="modal-dialog" style="width: 800px;">
        <div class="modal-content">
            <form id="form-map" name="form-map" class="form-horizontal" role="form" method="post">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close"
                            onclick="$.clearModal($('#form-map'), $('#modal-map'))">
                        <span aria-hidden="true">&times;</span></button>
                    <b class="modal-title" id="label-map">地图展示</b>
                </div>
                <div class="modal-body">
                    <iframe src="fault/roadPoleAuditMap.html" id="myMap"
                            style="width: 100%;height: 365px"
                            frameBorder=0
                            scrolling=no></iframe>
                </div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-primary btn-flat"
                            onclick="$.clearModal($('#form-map'), $('#modal-map'))">
                        <span class="glyphicon glyphicon-ok" aria-hidden="true"></span> 完成
                    </button>
                </div>
            </form>
        </div>
    </div>
</div>

<div class="modal fade" tabindex="-1" role="dialog" id="modal-signFaultStatus">
    <div class="modal-dialog" role="document">
        <div class="modal-content" style="width: 610px;overflow-y:hidden;overflow-x: hidden">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span>
                </button>
                <h4 class="modal-title">故障进度</h4>
            </div>
            <div class="modal-body" style="overflow-y:hidden;overflow-x: hidden">
                <div class="ystep2" style="width: auto"></div>
                <div>
                    <table id="operationRecord" class="table table-bordered table-striped">
                        <tr>
                            <th>环节名称</th>
                            <th>到达时间</th>
                            <th>处理时间</th>
                            <th>处理人</th>
                            <th>操作类型</th>
                        </tr>
                        <tr>
                            <td>故障申报</td>
                            <td></td>
                            <td></td>
                            <td></td>
                            <td></td>
                        </tr>
                        <tr>
                            <td>内部审核</td>
                            <td></td>
                            <td></td>
                            <td></td>
                            <td></td>
                        </tr>
                        <tr>
                            <td>上报监管单位</td>
                            <td>--</td>
                            <td>--</td>
                            <td>--</td>
                            <td>--</td>
                        </tr>
                        <tr>
                            <td>监管单位审核</td>
                            <td></td>
                            <td></td>
                            <td></td>
                            <td></td>
                        </tr>
                        <tr>
                            <td>故障处理</td>
                            <td></td>
                            <td></td>
                            <td></td>
                            <td></td>
                        </tr>
                    </table>
                </div>
            </div>
        </div><!-- /.modal-content -->
    </div><!-- /.modal-dialog -->
</div><!-- /.modal -->

</body>

<script src="../plugins/oss-h5-upload-js-direct/lib/plupload-2.1.2/js/plupload.full.min.js"></script>
<script src="../plugins/oss-h5-upload-js-direct/lib/crypto1/crypto/crypto.js"></script>
<script src="../plugins/oss-h5-upload-js-direct/lib/crypto1/hmac/hmac.js"></script>
<script src="../plugins/oss-h5-upload-js-direct/lib/crypto1/sha1/sha1.js"></script>
<script src="../plugins/oss-h5-upload-js-direct/lib/base64.js"></script>
<script src="../plugins/oss-h5-upload-js-direct/upload.js"></script>
<!----------------->
<script src="fault/highLeverReport.js"></script>
</html>